<?php
	defined( '_JEXEC' ) or die();
	$user = &JFactory::getUser();
?>
<script type="text/javascript" src="<?php echo JURI::base(); ?>components/com_wrd/assets/js/jquery-1.4.2.min.js"></script>
<div id="cpanel" style="float:left;width:55%;">

	<?php if($user->authorise('wrd.report.revenue', 'com_wrd')): ?>
    <div style="float: left;">
        <div class="icon">
            <a href="#" onclick="jQuery('#revenueReport').toggle();">
                <img width="48" alt="<?php echo JText::_('Revenue Report'); ?>" src="components/com_wrd/assets/images/gifts-reports.png"/>
                <span><?php echo JText::_('Revenue Report'); ?></span>
            </a>
        </div>
    </div>
    <?php endif; ?>
    
    <?php if($user->authorise('wrd.report.membership', 'com_wrd')): ?>
    <div style="float: left;">
        <div class="icon">
            <a href="index.php?option=com_wrd&controller=reports&layout=membershipclub">
                <img width="48" alt="<?php echo JText::_('Membership Report'); ?>" src="components/com_wrd/assets/images/gifts-reports.png"/>
                <span><?php echo JText::_('Membership Report'); ?></span>
            </a>
        </div>
    </div>
    <?php endif; ?>
    
	<?php if($user->authorise('wrd.report.member', 'com_wrd')): ?>
    <div style="float: left;">
        <div class="icon">
            <a href="index.php?option=com_wrd&controller=reports&layout=memberbirthday">
                <img width="48" alt="<?php echo JText::_('Member Birthday'); ?>" src="components/com_wrd/assets/images/gifts-reports.png"/>
                <span><?php echo JText::_('Member Birthday'); ?></span>
            </a>
        </div>
    </div>
    <?php endif; ?>
    
    <?php if($user->authorise('wrd.report.summary_member_spending', 'com_wrd')): ?>
	<div style="float: left;">
        <div class="icon">
            <a href="index.php?option=com_wrd&controller=reports&layout=outletreport">
                <img width="48" alt="<?php echo JText::_('Summary Member Spending Report'); ?>" src="components/com_wrd/assets/images/gifts-reports.png"/>
                <span><?php echo JText::_('Summary Member Spending Report'); ?></span>
            </a>
        </div>
    </div><?php endif; ?>
	
	<?php if($user->authorise('wrd.report.memberstatistic', 'com_wrd')): ?>
    <div style="float: left;">
        <div class="icon">
            <a href="#" onclick="jQuery('#member_statistic').toggle();">
                <img width="48" alt="<?php echo JText::_('Member Statistic'); ?>" src="components/com_wrd/assets/images/gifts-reports.png"/>
                <span><?php echo JText::_('Member Statistic'); ?></span>
            </a>
        </div>
    </div>
    <?php endif; ?>
    
    <?php if($user->authorise('wrd.report.complain', 'com_wrd')): ?>
    <div style="float: left;">
        <div class="icon">
            <a href="index.php?option=com_wrd&controller=reports&layout=complainreport">
                <img width="48" alt="<?php echo JText::_('Complain Report'); ?>" src="components/com_wrd/assets/images/gifts-reports.png"/>
                <span><?php echo JText::_('Complain Report'); ?></span>
            </a>
        </div>
    </div>
    <?php endif; ?>
    
    <?php if($user->authorise('wrd.report.memberservice', 'com_wrd')): ?>
    <div style="float: left;">
        <div class="icon">
            <a href="index.php?option=com_wrd&controller=reports&layout=memberservicereport">
                <img width="48" alt="<?php echo JText::_('Member Service Report'); ?>" src="components/com_wrd/assets/images/gifts-reports.png"/>
                <span><?php echo JText::_('Member Service Report'); ?></span>
            </a>
        </div>
    </div>
    <?php endif; ?>
    
    <?php if($user->authorise('wrd.report.giftsredemption', 'com_wrd')): ?>
    <div style="float: left;">
        <div class="icon">
			<a href="#" onclick="jQuery('#giftreport').toggle();">
            <img width="48" alt="<?php echo JText::_('Gifts Redemption Reports'); ?>" src="components/com_wrd/assets/images/gifts-reports.png"/>
            <span><?php echo JText::_('Gifts Redemption Reports'); ?></span></a>
        </div>
    </div>
    <?php endif; ?>
	
	
	<?php if($user->authorise('wrd.report.systemcheck', 'com_wrd')): ?>
		<div style="float: left;">
			<div class="icon">
				<a href="index.php?option=com_wrd&controller=reports&layout=systemcheck">
					<img width="48" alt="<?php echo JText::_('System Check'); ?>" src="components/com_wrd/assets/images/systemcheck.png"/>
					<span><?php echo JText::_('System Check'); ?></span>
				</a>
			</div>
		</div>
	<?php endif; ?>
		
	<div id="member_statistic" style="display: none;">
			<?php if($user->authorise('wrd.report.membersstatistics', 'com_wrd')): ?>
			<div style="float: left;">
				<div class="icon">
					<a href="index.php?option=com_wrd&controller=reports&layout=memberstatistic">
						<img width="48" alt="<?php echo JText::_('Members statistics'); ?>" src="components/com_wrd/assets/images/excel.png"/>
						<span><?php echo JText::_('Members statistics'); ?></span>
					</a>
				</div>
			</div><?php endif; ?>
			
			<?php if($user->authorise('wrd.report.membersstatisticsjob', 'com_wrd')): ?>
			<div style="float: left;">
				<div class="icon">
					<a href="index.php?option=com_wrd&controller=reports&layout=memberstatisticjob">
						<img width="48" alt="<?php echo JText::_('Members statistics on job'); ?>" src="components/com_wrd/assets/images/excel.png"/>
						<span><?php echo JText::_('Members statistics on job'); ?></span>
					</a>
				</div>
			</div><?php endif; ?>
			
			<?php if($user->authorise('wrd.report.masterlist', 'com_wrd')): ?>
			<div style="float: left;">
				<div class="icon">
					<a href="index.php?option=com_wrd&controller=reports&layout=memberreport">
						<img width="48" alt="<?php echo JText::_('Master List Report'); ?>" src="components/com_wrd/assets/images/excel.png"/>
						<span><?php echo JText::_('Master List Report'); ?></span>
					</a>
				</div>
			</div>
			
			<?php endif; ?>
		</div> <!-- end div#member_statistic-->	
		
    <div id="revenueReport" style="display: none; clear: both;">
    	<?php if($user->authorise('wrd.report.top_spending', 'com_wrd')): ?>
        <div style="float: left;">
            <div class="icon">
                <a href="index.php?option=com_wrd&controller=reports&layout=generalreport">
                    <img width="48" alt="<?php echo JText::_('Top Spending Report'); ?>" src="components/com_wrd/assets/images/excel.png"/>
                    <span><?php echo JText::_('Top Spending Report'); ?></span>
                </a>
            </div>
        </div><?php endif; ?>
        
        <?php if($user->authorise('wrd.report.outlet_revenue', 'com_wrd')): ?>
        <div style="float: left;">
            <div class="icon">
                <a href="index.php?option=com_wrd&controller=reports&layout=memberpendingreportsum">
                    <img width="48" alt="<?php echo JText::_('Outlets Revenue Reports'); ?>" src="components/com_wrd/assets/images/excel.png"/>
                    <span><?php echo JText::_('Outlets Revenue Reports'); ?></span>
                </a>
            </div>
        </div><?php endif; ?>
        
        <?php if($user->authorise('wrd.report.transaction', 'com_wrd')): ?>
		<div style="float: left;">
            <div class="icon">
                <a href="index.php?option=com_wrd&controller=reports&layout=transactionreport">
                    <img width="48" alt="<?php echo JText::_('Report transaction'); ?>" src="components/com_wrd/assets/images/excel.png"/>
                    <span><?php echo JText::_('Transaction report'); ?></span>
                </a>
            </div>
        </div><?php endif; ?>
        
        <?php if($user->authorise('wrd.report.transactionforweb', 'com_wrd')): ?>
		<div style="float: left;">
            <div class="icon">
                <a href="index.php?option=com_wrd&controller=reports&layout=transactionreportweb">
                    <img width="48" alt="<?php echo JText::_('Report transaction for web'); ?>" src="components/com_wrd/assets/images/excel.png"/>
                    <span><?php echo JText::_('Transaction report for Web'); ?></span>
                </a>
            </div>
        </div>
        <?php endif; ?>
    </div>
	
	<div id="giftreport" style="display: none; clear: both;">
    	<?php if($user->authorise('wrd.report.giftredemptionold', 'com_wrd')): ?>
        <div style="float: left;">
            <div class="icon">
                <a href="index.php?option=com_wrd&controller=reports&layout=redemptionreport">
                    <img width="48" alt="<?php echo JText::_('Gift Redemptions Reports Old'); ?>" src="components/com_wrd/assets/images/excel.png"/>
                    <span><?php echo JText::_('Gift Redemptions Reports Old'); ?></span>
                </a>
            </div>
        </div>
        <?php endif; ?>
        
        <?php if($user->authorise('wrd.report.giftredemptionproduct', 'com_wrd')): ?>
        <div style="float: left;">
            <div class="icon">
                <a href="index.php?option=com_wrd&controller=reports&layout=redemptionreportproduct">
                    <img width="48" alt="<?php echo JText::_('Gift Redemptions Reports Product'); ?>" src="components/com_wrd/assets/images/excel.png"/>
                    <span><?php echo JText::_('Gift Redemptions Reports Product'); ?></span>
                </a>
            </div>
        </div>
        <?php endif; ?>
		
		<?php if($user->authorise('wrd.report.giftredemptionvoucher', 'com_wrd')): ?>
        <div style="float: left;">
            <div class="icon">
                <a href="index.php?option=com_wrd&controller=reports&layout=redemptionreportvoucher">
                    <img width="48" alt="<?php echo JText::_('Gift Redemptions Reports Voucher'); ?>" src="components/com_wrd/assets/images/excel.png"/>
                    <span><?php echo JText::_('Gift Redemptions Reports Voucher'); ?></span>
                </a>
            </div>
        </div>
        <?php endif; ?>
		
		<?php if($user->authorise('wrd.report.approvevoucher', 'com_wrd')): ?>
        <div style="float: left;">
            <div class="icon">
                <a href="index.php?option=com_wrd&controller=reports&layout=approvevoucher">
                    <img width="48" alt="<?php echo JText::_('Approved Voucher'); ?>" src="components/com_wrd/assets/images/free_gift.png"/>
                    <span><?php echo JText::_('Approve Voucher'); ?></span>
                </a>
            </div>
        </div>
        <?php endif; ?>
		
		<?php if($user->authorise('wrd.report.redemption', 'com_wrd')): ?>
        <div style="float: left;">
            <div class="icon">
                <a href="index.php?option=com_wrd&controller=reports&layout=redempreport">
                    <img width="48" alt="<?php echo JText::_('Redemption Report'); ?>" src="components/com_wrd/assets/images/excel.png"/>
                    <span><?php echo JText::_('Redemption Report'); ?></span>
                </a>
            </div>
        </div>
        <?php endif; ?>
		
		<?php if($user->authorise('wrd.report.redemptiondetail', 'com_wrd')): ?>
        <div style="float: left;">
            <div class="icon">
                <a href="index.php?option=com_wrd&controller=reports&layout=redempreportdetail">
                    <img width="48" alt="<?php echo JText::_('Redemption Report'); ?>" src="components/com_wrd/assets/images/excel.png"/>
                    <span><?php echo JText::_('Redemption Report detail'); ?></span>
                </a>
            </div>
        </div>
        <?php endif; ?>
		
    </div><!-- end div#giftreport -->
	
</div>
